3.2.75 \(\int \frac {(h+i x)^4 (a+b \log (c (e+f x)))}{d e+d f x} \, dx\) [175]

Optimal. Leaf size=315 \[ -\frac {4 b i (f h-e i)^3 x}{d f^4}-\frac {3 b i^2 (f h-e i)^2 (e+f x)^2}{2 d f^5}-\frac {4 b i^3 (f h-e i) (e+f x)^3}{9 d f^5}-\frac {b i^4 (e+f x)^4}{16 d f^5}-\frac {b (f h-e i)^4 \log ^2(e+f x)}{2 d f^5}+\frac {4 i (f h-e i)^3 (e+f x) (a+b \log (c (e+f x)))}{d f^5}+\frac {3 i^2 (f h-e i)^2 (e+f x)^2 (a+b \log (c (e+f x)))}{d f^5}+\frac {4 i^3 (f h-e i) (e+f x)^3 (a+b \log (c (e+f x)))}{3 d f^5}+\frac {i^4 (e+f x)^4 (a+b \log (c (e+f x)))}{4 d f^5}+\frac {(f h-e i)^4 \log (e+f x) (a+b \log (c (e+f x)))}{d f^5} \]

[Out]

-4*b*i*(-e*i+f*h)^3*x/d/f^4-3/2*b*i^2*(-e*i+f*h)^2*(f*x+e)^2/d/f^5-4/9*b*i^3*(-e*i+f*h)*(f*x+e)^3/d/f^5-1/16*b
*i^4*(f*x+e)^4/d/f^5-1/2*b*(-e*i+f*h)^4*ln(f*x+e)^2/d/f^5+4*i*(-e*i+f*h)^3*(f*x+e)*(a+b*ln(c*(f*x+e)))/d/f^5+3
*i^2*(-e*i+f*h)^2*(f*x+e)^2*(a+b*ln(c*(f*x+e)))/d/f^5+4/3*i^3*(-e*i+f*h)*(f*x+e)^3*(a+b*ln(c*(f*x+e)))/d/f^5+1
/4*i^4*(f*x+e)^4*(a+b*ln(c*(f*x+e)))/d/f^5+(-e*i+f*h)^4*ln(f*x+e)*(a+b*ln(c*(f*x+e)))/d/f^5

________________________________________________________________________________________

Rubi [A]
time = 0.36, antiderivative size = 315, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {2458, 12, 45, 2372, 2338} \begin {gather*} \frac {4 i^3 (e+f x)^3 (f h-e i) (a+b \log (c (e+f x)))}{3 d f^5}+\frac {3 i^2 (e+f x)^2 (f h-e i)^2 (a+b \log (c (e+f x)))}{d f^5}+\frac {(f h-e i)^4 \log (e+f x) (a+b \log (c (e+f x)))}{d f^5}+\frac {4 i (e+f x) (f h-e i)^3 (a+b \log (c (e+f x)))}{d f^5}+\frac {i^4 (e+f x)^4 (a+b \log (c (e+f x)))}{4 d f^5}-\frac {4 b i^3 (e+f x)^3 (f h-e i)}{9 d f^5}-\frac {3 b i^2 (e+f x)^2 (f h-e i)^2}{2 d f^5}-\frac {b (f h-e i)^4 \log ^2(e+f x)}{2 d f^5}-\frac {b i^4 (e+f x)^4}{16 d f^5}-\frac {4 b i x (f h-e i)^3}{d f^4} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[((h + i*x)^4*(a + b*Log[c*(e + f*x)]))/(d*e + d*f*x),x]

[Out]

(-4*b*i*(f*h - e*i)^3*x)/(d*f^4) - (3*b*i^2*(f*h - e*i)^2*(e + f*x)^2)/(2*d*f^5) - (4*b*i^3*(f*h - e*i)*(e + f
*x)^3)/(9*d*f^5) - (b*i^4*(e + f*x)^4)/(16*d*f^5) - (b*(f*h - e*i)^4*Log[e + f*x]^2)/(2*d*f^5) + (4*i*(f*h - e
*i)^3*(e + f*x)*(a + b*Log[c*(e + f*x)]))/(d*f^5) + (3*i^2*(f*h - e*i)^2*(e + f*x)^2*(a + b*Log[c*(e + f*x)]))
/(d*f^5) + (4*i^3*(f*h - e*i)*(e + f*x)^3*(a + b*Log[c*(e + f*x)]))/(3*d*f^5) + (i^4*(e + f*x)^4*(a + b*Log[c*
(e + f*x)]))/(4*d*f^5) + ((f*h - e*i)^4*Log[e + f*x]*(a + b*Log[c*(e + f*x)]))/(d*f^5)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 45

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rule 2338

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rule 2372

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(x_)^(m_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol] :> With[{u = I
ntHide[x^m*(d + e*x^r)^q, x]}, Dist[a + b*Log[c*x^n], u, x] - Dist[b*n, Int[SimplifyIntegrand[u/x, x], x], x]]
 /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[q, 0] && IntegerQ[m] &&  !(EqQ[q, 1] && EqQ[m, -1])

Rule 2458

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + (g_.)*(x_))^(q_.)*((h_.) + (i_.)*(x_))
^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[(g*(x/e))^q*((e*h - d*i)/e + i*(x/e))^r*(a + b*Log[c*x^n])^p, x], x,
d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, n, p, q, r}, x] && EqQ[e*f - d*g, 0] && (IGtQ[p, 0] || IGtQ[
r, 0]) && IntegerQ[2*r]

Rubi steps

\begin {align*} \int \frac {(h+175 x)^4 (a+b \log (c (e+f x)))}{d e+d f x} \, dx &=\frac {\text {Subst}\left (\int \frac {\left (\frac {-175 e+f h}{f}+\frac {175 x}{f}\right )^4 (a+b \log (c x))}{d x} \, dx,x,e+f x\right )}{f}\\ &=\frac {\text {Subst}\left (\int \frac {\left (\frac {-175 e+f h}{f}+\frac {175 x}{f}\right )^4 (a+b \log (c x))}{x} \, dx,x,e+f x\right )}{d f}\\ &=-\frac {\left (\frac {8400 (175 e-f h)^3 (e+f x)}{f^4}-\frac {1102500 (175 e-f h)^2 (e+f x)^2}{f^4}+\frac {85750000 (175 e-f h) (e+f x)^3}{f^4}-\frac {2813671875 (e+f x)^4}{f^4}-\frac {12 (175 e-f h)^4 \log (e+f x)}{f^4}\right ) (a+b \log (c (e+f x)))}{12 d f}-\frac {b \text {Subst}\left (\int \frac {-8400 (175 e-f h)^3+1102500 (-175 e+f h)^2 x-85750000 (175 e-f h) x^2+2813671875 x^3+\frac {12 (-175 e+f h)^4 \log (x)}{x}}{12 f^4} \, dx,x,e+f x\right )}{d f}\\ &=-\frac {\left (\frac {8400 (175 e-f h)^3 (e+f x)}{f^4}-\frac {1102500 (175 e-f h)^2 (e+f x)^2}{f^4}+\frac {85750000 (175 e-f h) (e+f x)^3}{f^4}-\frac {2813671875 (e+f x)^4}{f^4}-\frac {12 (175 e-f h)^4 \log (e+f x)}{f^4}\right ) (a+b \log (c (e+f x)))}{12 d f}-\frac {b \text {Subst}\left (\int \left (-8400 (175 e-f h)^3+1102500 (-175 e+f h)^2 x-85750000 (175 e-f h) x^2+2813671875 x^3+\frac {12 (-175 e+f h)^4 \log (x)}{x}\right ) \, dx,x,e+f x\right )}{12 d f^5}\\ &=\frac {700 b (175 e-f h)^3 x}{d f^4}-\frac {91875 b (175 e-f h)^2 (e+f x)^2}{2 d f^5}+\frac {21437500 b (175 e-f h) (e+f x)^3}{9 d f^5}-\frac {937890625 b (e+f x)^4}{16 d f^5}-\frac {\left (\frac {8400 (175 e-f h)^3 (e+f x)}{f^4}-\frac {1102500 (175 e-f h)^2 (e+f x)^2}{f^4}+\frac {85750000 (175 e-f h) (e+f x)^3}{f^4}-\frac {2813671875 (e+f x)^4}{f^4}-\frac {12 (175 e-f h)^4 \log (e+f x)}{f^4}\right ) (a+b \log (c (e+f x)))}{12 d f}-\frac {\left (b (175 e-f h)^4\right ) \text {Subst}\left (\int \frac {\log (x)}{x} \, dx,x,e+f x\right )}{d f^5}\\ &=\frac {700 b (175 e-f h)^3 x}{d f^4}-\frac {91875 b (175 e-f h)^2 (e+f x)^2}{2 d f^5}+\frac {21437500 b (175 e-f h) (e+f x)^3}{9 d f^5}-\frac {937890625 b (e+f x)^4}{16 d f^5}-\frac {b (175 e-f h)^4 \log ^2(e+f x)}{2 d f^5}-\frac {\left (\frac {8400 (175 e-f h)^3 (e+f x)}{f^4}-\frac {1102500 (175 e-f h)^2 (e+f x)^2}{f^4}+\frac {85750000 (175 e-f h) (e+f x)^3}{f^4}-\frac {2813671875 (e+f x)^4}{f^4}-\frac {12 (175 e-f h)^4 \log (e+f x)}{f^4}\right ) (a+b \log (c (e+f x)))}{12 d f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.38, size = 589, normalized size = 1.87 \begin {gather*} \frac {72 a^2 f^4 h^4-288 a^2 e f^3 h^3 i+432 a^2 e^2 f^2 h^2 i^2-288 a^2 e^3 f h i^3+72 a^2 e^4 i^4+576 a b f^4 h^3 i x-576 b^2 f^4 h^3 i x-864 a b e f^3 h^2 i^2 x+1296 b^2 e f^3 h^2 i^2 x+576 a b e^2 f^2 h i^3 x-1056 b^2 e^2 f^2 h i^3 x-144 a b e^3 f i^4 x+300 b^2 e^3 f i^4 x+432 a b f^4 h^2 i^2 x^2-216 b^2 f^4 h^2 i^2 x^2-288 a b e f^3 h i^3 x^2+240 b^2 e f^3 h i^3 x^2+72 a b e^2 f^2 i^4 x^2-78 b^2 e^2 f^2 i^4 x^2+192 a b f^4 h i^3 x^3-64 b^2 f^4 h i^3 x^3-48 a b e f^3 i^4 x^3+28 b^2 e f^3 i^4 x^3+36 a b f^4 i^4 x^4-9 b^2 f^4 i^4 x^4-12 b^2 e^2 i^2 \left (36 f^2 h^2-40 e f h i+13 e^2 i^2\right ) \log (e+f x)+12 b \left (12 a (f h-e i)^4+b i \left (-12 e^4 i^3-12 e^3 f i^2 (-4 h+i x)+6 e^2 f^2 i \left (-12 h^2+8 h i x+i^2 x^2\right )+4 e f^3 \left (12 h^3-18 h^2 i x-6 h i^2 x^2-i^3 x^3\right )+f^4 x \left (48 h^3+36 h^2 i x+16 h i^2 x^2+3 i^3 x^3\right )\right )\right ) \log (c (e+f x))+72 b^2 (f h-e i)^4 \log ^2(c (e+f x))}{144 b d f^5} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[((h + i*x)^4*(a + b*Log[c*(e + f*x)]))/(d*e + d*f*x),x]

[Out]

(72*a^2*f^4*h^4 - 288*a^2*e*f^3*h^3*i + 432*a^2*e^2*f^2*h^2*i^2 - 288*a^2*e^3*f*h*i^3 + 72*a^2*e^4*i^4 + 576*a
*b*f^4*h^3*i*x - 576*b^2*f^4*h^3*i*x - 864*a*b*e*f^3*h^2*i^2*x + 1296*b^2*e*f^3*h^2*i^2*x + 576*a*b*e^2*f^2*h*
i^3*x - 1056*b^2*e^2*f^2*h*i^3*x - 144*a*b*e^3*f*i^4*x + 300*b^2*e^3*f*i^4*x + 432*a*b*f^4*h^2*i^2*x^2 - 216*b
^2*f^4*h^2*i^2*x^2 - 288*a*b*e*f^3*h*i^3*x^2 + 240*b^2*e*f^3*h*i^3*x^2 + 72*a*b*e^2*f^2*i^4*x^2 - 78*b^2*e^2*f
^2*i^4*x^2 + 192*a*b*f^4*h*i^3*x^3 - 64*b^2*f^4*h*i^3*x^3 - 48*a*b*e*f^3*i^4*x^3 + 28*b^2*e*f^3*i^4*x^3 + 36*a
*b*f^4*i^4*x^4 - 9*b^2*f^4*i^4*x^4 - 12*b^2*e^2*i^2*(36*f^2*h^2 - 40*e*f*h*i + 13*e^2*i^2)*Log[e + f*x] + 12*b
*(12*a*(f*h - e*i)^4 + b*i*(-12*e^4*i^3 - 12*e^3*f*i^2*(-4*h + i*x) + 6*e^2*f^2*i*(-12*h^2 + 8*h*i*x + i^2*x^2
) + 4*e*f^3*(12*h^3 - 18*h^2*i*x - 6*h*i^2*x^2 - i^3*x^3) + f^4*x*(48*h^3 + 36*h^2*i*x + 16*h*i^2*x^2 + 3*i^3*
x^3)))*Log[c*(e + f*x)] + 72*b^2*(f*h - e*i)^4*Log[c*(e + f*x)]^2)/(144*b*d*f^5)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(987\) vs. \(2(303)=606\).
time = 0.68, size = 988, normalized size = 3.14 Too large to display

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((i*x+h)^4*(a+b*ln(c*(f*x+e)))/(d*f*x+d*e),x,method=_RETURNVERBOSE)

[Out]

1/c/f*(1/c^3/f^4/d*b*i^4*(1/4*(c*f*x+c*e)^4*ln(c*f*x+c*e)-1/16*(c*f*x+c*e)^4)+6*c/f^2/d*a*e^2*h^2*i^2*ln(c*f*x
+c*e)-12/c/f^3/d*b*e*h*i^3*(1/2*(c*f*x+c*e)^2*ln(c*f*x+c*e)-1/4*(c*f*x+c*e)^2)+3*c/f^2/d*b*e^2*h^2*i^2*ln(c*f*
x+c*e)^2-2*c/f^3/d*b*e^3*h*i^3*ln(c*f*x+c*e)^2-2*c/f/d*b*e*h^3*i*ln(c*f*x+c*e)^2-4*c/f/d*a*e*h^3*i*ln(c*f*x+c*
e)-4*c/f^3/d*a*e^3*h*i^3*ln(c*f*x+c*e)-6/c/f^3/d*a*e*h*i^3*(c*f*x+c*e)^2-4/3/c^2/f^4/d*a*e*i^4*(c*f*x+c*e)^3+3
/c/f^2/d*a*h^2*i^2*(c*f*x+c*e)^2-12/f^2/d*a*e*h^2*i^2*(c*f*x+c*e)+4/c^2/f^3/d*b*h*i^3*(1/3*(c*f*x+c*e)^3*ln(c*
f*x+c*e)-1/9*(c*f*x+c*e)^3)+12/f^3/d*a*e^2*h*i^3*(c*f*x+c*e)+c/f^4/d*a*e^4*i^4*ln(c*f*x+c*e)+4/f/d*a*h^3*i*(c*
f*x+c*e)-4/f^4/d*a*e^3*i^4*(c*f*x+c*e)+1/4/c^3/f^4/d*a*i^4*(c*f*x+c*e)^4-4/f^4/d*b*e^3*i^4*((c*f*x+c*e)*ln(c*f
*x+c*e)-c*f*x-c*e)+4/f/d*b*h^3*i*((c*f*x+c*e)*ln(c*f*x+c*e)-c*f*x-c*e)+6/c/f^4/d*b*e^2*i^4*(1/2*(c*f*x+c*e)^2*
ln(c*f*x+c*e)-1/4*(c*f*x+c*e)^2)+6/c/f^2/d*b*h^2*i^2*(1/2*(c*f*x+c*e)^2*ln(c*f*x+c*e)-1/4*(c*f*x+c*e)^2)+1/2*c
/d*b*h^4*ln(c*f*x+c*e)^2+c/d*a*h^4*ln(c*f*x+c*e)+4/3/c^2/f^3/d*a*h*i^3*(c*f*x+c*e)^3-12/f^2/d*b*e*h^2*i^2*((c*
f*x+c*e)*ln(c*f*x+c*e)-c*f*x-c*e)+3/c/f^4/d*a*e^2*i^4*(c*f*x+c*e)^2+12/f^3/d*b*e^2*h*i^3*((c*f*x+c*e)*ln(c*f*x
+c*e)-c*f*x-c*e)+1/2*c/f^4/d*b*e^4*i^4*ln(c*f*x+c*e)^2-4/c^2/f^4/d*b*e*i^4*(1/3*(c*f*x+c*e)^3*ln(c*f*x+c*e)-1/
9*(c*f*x+c*e)^3))

________________________________________________________________________________________

Maxima [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 744 vs. \(2 (296) = 592\).
time = 0.32, size = 744, normalized size = 2.36 \begin {gather*} -\frac {1}{2} \, b h^{4} {\left (\frac {2 \, \log \left (c f x + c e\right ) \log \left (d f x + d e\right )}{d f} - \frac {\log \left (f x + e\right )^{2} + 2 \, \log \left (f x + e\right ) \log \left (c\right )}{d f}\right )} + 4 i \, b h^{3} {\left (\frac {x}{d f} - \frac {e \log \left (f x + e\right )}{d f^{2}}\right )} \log \left (c f x + c e\right ) + 4 i \, a h^{3} {\left (\frac {x}{d f} - \frac {e \log \left (f x + e\right )}{d f^{2}}\right )} - 3 \, b h^{2} {\left (\frac {f x^{2} - 2 \, x e}{d f^{2}} + \frac {2 \, e^{2} \log \left (f x + e\right )}{d f^{3}}\right )} \log \left (c f x + c e\right ) + \frac {b h^{4} \log \left (c f x + c e\right ) \log \left (d f x + d e\right )}{d f} - 3 \, a h^{2} {\left (\frac {f x^{2} - 2 \, x e}{d f^{2}} + \frac {2 \, e^{2} \log \left (f x + e\right )}{d f^{3}}\right )} - \frac {2}{3} i \, b h {\left (\frac {2 \, f^{2} x^{3} - 3 \, f x^{2} e + 6 \, x e^{2}}{d f^{3}} - \frac {6 \, e^{3} \log \left (f x + e\right )}{d f^{4}}\right )} \log \left (c f x + c e\right ) + \frac {a h^{4} \log \left (d f x + d e\right )}{d f} - \frac {2}{3} i \, a h {\left (\frac {2 \, f^{2} x^{3} - 3 \, f x^{2} e + 6 \, x e^{2}}{d f^{3}} - \frac {6 \, e^{3} \log \left (f x + e\right )}{d f^{4}}\right )} + \frac {1}{12} \, b {\left (\frac {3 \, f^{3} x^{4} - 4 \, f^{2} x^{3} e + 6 \, f x^{2} e^{2} - 12 \, x e^{3}}{d f^{4}} + \frac {12 \, e^{4} \log \left (f x + e\right )}{d f^{5}}\right )} \log \left (c f x + c e\right ) + \frac {2 i \, {\left (e \log \left (f x + e\right )^{2} - 2 \, f x + 2 \, e \log \left (f x + e\right )\right )} b h^{3}}{d f^{2}} + \frac {1}{12} \, a {\left (\frac {3 \, f^{3} x^{4} - 4 \, f^{2} x^{3} e + 6 \, f x^{2} e^{2} - 12 \, x e^{3}}{d f^{4}} + \frac {12 \, e^{4} \log \left (f x + e\right )}{d f^{5}}\right )} + \frac {3 \, {\left (f^{2} x^{2} - 6 \, f x e + 2 \, e^{2} \log \left (f x + e\right )^{2} + 6 \, e^{2} \log \left (f x + e\right )\right )} b h^{2}}{2 \, d f^{3}} + \frac {i \, {\left (4 \, f^{3} x^{3} - 15 \, f^{2} x^{2} e + 66 \, f x e^{2} - 18 \, e^{3} \log \left (f x + e\right )^{2} - 66 \, e^{3} \log \left (f x + e\right )\right )} b h}{9 \, d f^{4}} - \frac {{\left (9 \, f^{4} x^{4} - 28 \, f^{3} x^{3} e + 78 \, f^{2} x^{2} e^{2} - 300 \, f x e^{3} + 72 \, e^{4} \log \left (f x + e\right )^{2} + 300 \, e^{4} \log \left (f x + e\right )\right )} b}{144 \, d f^{5}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^4*(a+b*log(c*(f*x+e)))/(d*f*x+d*e),x, algorithm="maxima")

[Out]

-1/2*b*h^4*(2*log(c*f*x + c*e)*log(d*f*x + d*e)/(d*f) - (log(f*x + e)^2 + 2*log(f*x + e)*log(c))/(d*f)) + 4*I*
b*h^3*(x/(d*f) - e*log(f*x + e)/(d*f^2))*log(c*f*x + c*e) + 4*I*a*h^3*(x/(d*f) - e*log(f*x + e)/(d*f^2)) - 3*b
*h^2*((f*x^2 - 2*x*e)/(d*f^2) + 2*e^2*log(f*x + e)/(d*f^3))*log(c*f*x + c*e) + b*h^4*log(c*f*x + c*e)*log(d*f*
x + d*e)/(d*f) - 3*a*h^2*((f*x^2 - 2*x*e)/(d*f^2) + 2*e^2*log(f*x + e)/(d*f^3)) - 2/3*I*b*h*((2*f^2*x^3 - 3*f*
x^2*e + 6*x*e^2)/(d*f^3) - 6*e^3*log(f*x + e)/(d*f^4))*log(c*f*x + c*e) + a*h^4*log(d*f*x + d*e)/(d*f) - 2/3*I
*a*h*((2*f^2*x^3 - 3*f*x^2*e + 6*x*e^2)/(d*f^3) - 6*e^3*log(f*x + e)/(d*f^4)) + 1/12*b*((3*f^3*x^4 - 4*f^2*x^3
*e + 6*f*x^2*e^2 - 12*x*e^3)/(d*f^4) + 12*e^4*log(f*x + e)/(d*f^5))*log(c*f*x + c*e) + 2*I*(e*log(f*x + e)^2 -
 2*f*x + 2*e*log(f*x + e))*b*h^3/(d*f^2) + 1/12*a*((3*f^3*x^4 - 4*f^2*x^3*e + 6*f*x^2*e^2 - 12*x*e^3)/(d*f^4)
+ 12*e^4*log(f*x + e)/(d*f^5)) + 3/2*(f^2*x^2 - 6*f*x*e + 2*e^2*log(f*x + e)^2 + 6*e^2*log(f*x + e))*b*h^2/(d*
f^3) + 1/9*I*(4*f^3*x^3 - 15*f^2*x^2*e + 66*f*x*e^2 - 18*e^3*log(f*x + e)^2 - 66*e^3*log(f*x + e))*b*h/(d*f^4)
 - 1/144*(9*f^4*x^4 - 28*f^3*x^3*e + 78*f^2*x^2*e^2 - 300*f*x*e^3 + 72*e^4*log(f*x + e)^2 + 300*e^4*log(f*x +
e))*b/(d*f^5)

________________________________________________________________________________________

Fricas [A]
time = 0.39, size = 408, normalized size = 1.30 \begin {gather*} -\frac {576 \, {\left (-i \, a + i \, b\right )} f^{4} h^{3} x + 216 \, {\left (2 \, a - b\right )} f^{4} h^{2} x^{2} + 64 \, {\left (3 i \, a - i \, b\right )} f^{4} h x^{3} - 9 \, {\left (4 \, a - b\right )} f^{4} x^{4} + 12 \, {\left (12 \, a - 25 \, b\right )} f x e^{3} - 72 \, {\left (b f^{4} h^{4} - 4 i \, b f^{3} h^{3} e - 6 \, b f^{2} h^{2} e^{2} + 4 i \, b f h e^{3} + b e^{4}\right )} \log \left (c f x + c e\right )^{2} + 6 \, {\left (16 \, {\left (6 i \, a - 11 i \, b\right )} f^{2} h x - {\left (12 \, a - 13 \, b\right )} f^{2} x^{2}\right )} e^{2} - 4 \, {\left (108 \, {\left (2 \, a - 3 \, b\right )} f^{3} h^{2} x - 12 \, {\left (-6 i \, a + 5 i \, b\right )} f^{3} h x^{2} - {\left (12 \, a - 7 \, b\right )} f^{3} x^{3}\right )} e - 12 \, {\left (12 \, a f^{4} h^{4} + 48 i \, b f^{4} h^{3} x - 36 \, b f^{4} h^{2} x^{2} - 16 i \, b f^{4} h x^{3} + 3 \, b f^{4} x^{4} + {\left (12 \, a - 25 \, b\right )} e^{4} - 4 \, {\left (2 \, {\left (-6 i \, a + 11 i \, b\right )} f h + 3 \, b f x\right )} e^{3} - 6 \, {\left (6 \, {\left (2 \, a - 3 \, b\right )} f^{2} h^{2} + 8 i \, b f^{2} h x - b f^{2} x^{2}\right )} e^{2} - 4 \, {\left (12 \, {\left (i \, a - i \, b\right )} f^{3} h^{3} - 18 \, b f^{3} h^{2} x - 6 i \, b f^{3} h x^{2} + b f^{3} x^{3}\right )} e\right )} \log \left (c f x + c e\right )}{144 \, d f^{5}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^4*(a+b*log(c*(f*x+e)))/(d*f*x+d*e),x, algorithm="fricas")

[Out]

-1/144*(576*(-I*a + I*b)*f^4*h^3*x + 216*(2*a - b)*f^4*h^2*x^2 + 64*(3*I*a - I*b)*f^4*h*x^3 - 9*(4*a - b)*f^4*
x^4 + 12*(12*a - 25*b)*f*x*e^3 - 72*(b*f^4*h^4 - 4*I*b*f^3*h^3*e - 6*b*f^2*h^2*e^2 + 4*I*b*f*h*e^3 + b*e^4)*lo
g(c*f*x + c*e)^2 + 6*(16*(6*I*a - 11*I*b)*f^2*h*x - (12*a - 13*b)*f^2*x^2)*e^2 - 4*(108*(2*a - 3*b)*f^3*h^2*x
- 12*(-6*I*a + 5*I*b)*f^3*h*x^2 - (12*a - 7*b)*f^3*x^3)*e - 12*(12*a*f^4*h^4 + 48*I*b*f^4*h^3*x - 36*b*f^4*h^2
*x^2 - 16*I*b*f^4*h*x^3 + 3*b*f^4*x^4 + (12*a - 25*b)*e^4 - 4*(2*(-6*I*a + 11*I*b)*f*h + 3*b*f*x)*e^3 - 6*(6*(
2*a - 3*b)*f^2*h^2 + 8*I*b*f^2*h*x - b*f^2*x^2)*e^2 - 4*(12*(I*a - I*b)*f^3*h^3 - 18*b*f^3*h^2*x - 6*I*b*f^3*h
*x^2 + b*f^3*x^3)*e)*log(c*f*x + c*e))/(d*f^5)

________________________________________________________________________________________

Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 682 vs. \(2 (289) = 578\).
time = 1.03, size = 682, normalized size = 2.17 \begin {gather*} x^{4} \left (\frac {a i^{4}}{4 d f} - \frac {b i^{4}}{16 d f}\right ) + x^{3} \left (- \frac {a e i^{4}}{3 d f^{2}} + \frac {4 a h i^{3}}{3 d f} + \frac {7 b e i^{4}}{36 d f^{2}} - \frac {4 b h i^{3}}{9 d f}\right ) + x^{2} \left (\frac {a e^{2} i^{4}}{2 d f^{3}} - \frac {2 a e h i^{3}}{d f^{2}} + \frac {3 a h^{2} i^{2}}{d f} - \frac {13 b e^{2} i^{4}}{24 d f^{3}} + \frac {5 b e h i^{3}}{3 d f^{2}} - \frac {3 b h^{2} i^{2}}{2 d f}\right ) + x \left (- \frac {a e^{3} i^{4}}{d f^{4}} + \frac {4 a e^{2} h i^{3}}{d f^{3}} - \frac {6 a e h^{2} i^{2}}{d f^{2}} + \frac {4 a h^{3} i}{d f} + \frac {25 b e^{3} i^{4}}{12 d f^{4}} - \frac {22 b e^{2} h i^{3}}{3 d f^{3}} + \frac {9 b e h^{2} i^{2}}{d f^{2}} - \frac {4 b h^{3} i}{d f}\right ) + \frac {\left (- 12 b e^{3} i^{4} x + 48 b e^{2} f h i^{3} x + 6 b e^{2} f i^{4} x^{2} - 72 b e f^{2} h^{2} i^{2} x - 24 b e f^{2} h i^{3} x^{2} - 4 b e f^{2} i^{4} x^{3} + 48 b f^{3} h^{3} i x + 36 b f^{3} h^{2} i^{2} x^{2} + 16 b f^{3} h i^{3} x^{3} + 3 b f^{3} i^{4} x^{4}\right ) \log {\left (c \left (e + f x\right ) \right )}}{12 d f^{4}} + \frac {\left (b e^{4} i^{4} - 4 b e^{3} f h i^{3} + 6 b e^{2} f^{2} h^{2} i^{2} - 4 b e f^{3} h^{3} i + b f^{4} h^{4}\right ) \log {\left (c \left (e + f x\right ) \right )}^{2}}{2 d f^{5}} + \frac {\left (12 a e^{4} i^{4} - 48 a e^{3} f h i^{3} + 72 a e^{2} f^{2} h^{2} i^{2} - 48 a e f^{3} h^{3} i + 12 a f^{4} h^{4} - 25 b e^{4} i^{4} + 88 b e^{3} f h i^{3} - 108 b e^{2} f^{2} h^{2} i^{2} + 48 b e f^{3} h^{3} i\right ) \log {\left (e + f x \right )}}{12 d f^{5}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)**4*(a+b*ln(c*(f*x+e)))/(d*f*x+d*e),x)

[Out]

x**4*(a*i**4/(4*d*f) - b*i**4/(16*d*f)) + x**3*(-a*e*i**4/(3*d*f**2) + 4*a*h*i**3/(3*d*f) + 7*b*e*i**4/(36*d*f
**2) - 4*b*h*i**3/(9*d*f)) + x**2*(a*e**2*i**4/(2*d*f**3) - 2*a*e*h*i**3/(d*f**2) + 3*a*h**2*i**2/(d*f) - 13*b
*e**2*i**4/(24*d*f**3) + 5*b*e*h*i**3/(3*d*f**2) - 3*b*h**2*i**2/(2*d*f)) + x*(-a*e**3*i**4/(d*f**4) + 4*a*e**
2*h*i**3/(d*f**3) - 6*a*e*h**2*i**2/(d*f**2) + 4*a*h**3*i/(d*f) + 25*b*e**3*i**4/(12*d*f**4) - 22*b*e**2*h*i**
3/(3*d*f**3) + 9*b*e*h**2*i**2/(d*f**2) - 4*b*h**3*i/(d*f)) + (-12*b*e**3*i**4*x + 48*b*e**2*f*h*i**3*x + 6*b*
e**2*f*i**4*x**2 - 72*b*e*f**2*h**2*i**2*x - 24*b*e*f**2*h*i**3*x**2 - 4*b*e*f**2*i**4*x**3 + 48*b*f**3*h**3*i
*x + 36*b*f**3*h**2*i**2*x**2 + 16*b*f**3*h*i**3*x**3 + 3*b*f**3*i**4*x**4)*log(c*(e + f*x))/(12*d*f**4) + (b*
e**4*i**4 - 4*b*e**3*f*h*i**3 + 6*b*e**2*f**2*h**2*i**2 - 4*b*e*f**3*h**3*i + b*f**4*h**4)*log(c*(e + f*x))**2
/(2*d*f**5) + (12*a*e**4*i**4 - 48*a*e**3*f*h*i**3 + 72*a*e**2*f**2*h**2*i**2 - 48*a*e*f**3*h**3*i + 12*a*f**4
*h**4 - 25*b*e**4*i**4 + 88*b*e**3*f*h*i**3 - 108*b*e**2*f**2*h**2*i**2 + 48*b*e*f**3*h**3*i)*log(e + f*x)/(12
*d*f**5)

________________________________________________________________________________________

Giac [B] Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 664 vs. \(2 (296) = 592\).
time = 5.87, size = 664, normalized size = 2.11 \begin {gather*} \frac {72 \, b f^{4} h^{4} \log \left (c f x + c e\right )^{2} + 576 i \, b f^{4} h^{3} x \log \left (c f x + c e\right ) - 432 \, b f^{4} h^{2} x^{2} \log \left (c f x + c e\right ) - 192 i \, b f^{4} h x^{3} \log \left (c f x + c e\right ) + 36 \, b f^{4} x^{4} \log \left (c f x + c e\right ) - 288 i \, b f^{3} h^{3} e \log \left (c f x + c e\right )^{2} + 144 \, a f^{4} h^{4} \log \left (f x + e\right ) + 576 i \, a f^{4} h^{3} x - 576 i \, b f^{4} h^{3} x - 432 \, a f^{4} h^{2} x^{2} + 216 \, b f^{4} h^{2} x^{2} - 192 i \, a f^{4} h x^{3} + 64 i \, b f^{4} h x^{3} + 36 \, a f^{4} x^{4} - 9 \, b f^{4} x^{4} + 864 \, b f^{3} h^{2} x e \log \left (c f x + c e\right ) + 288 i \, b f^{3} h x^{2} e \log \left (c f x + c e\right ) - 48 \, b f^{3} x^{3} e \log \left (c f x + c e\right ) - 576 i \, a f^{3} h^{3} e \log \left (f x + e\right ) + 576 i \, b f^{3} h^{3} e \log \left (f x + e\right ) + 864 \, a f^{3} h^{2} x e - 1296 \, b f^{3} h^{2} x e + 288 i \, a f^{3} h x^{2} e - 240 i \, b f^{3} h x^{2} e - 48 \, a f^{3} x^{3} e + 28 \, b f^{3} x^{3} e - 432 \, b f^{2} h^{2} e^{2} \log \left (c f x + c e\right )^{2} - 576 i \, b f^{2} h x e^{2} \log \left (c f x + c e\right ) + 72 \, b f^{2} x^{2} e^{2} \log \left (c f x + c e\right ) - 864 \, a f^{2} h^{2} e^{2} \log \left (f x + e\right ) + 1296 \, b f^{2} h^{2} e^{2} \log \left (f x + e\right ) - 576 i \, a f^{2} h x e^{2} + 1056 i \, b f^{2} h x e^{2} + 72 \, a f^{2} x^{2} e^{2} - 78 \, b f^{2} x^{2} e^{2} + 288 i \, b f h e^{3} \log \left (c f x + c e\right )^{2} - 144 \, b f x e^{3} \log \left (c f x + c e\right ) + 576 i \, a f h e^{3} \log \left (f x + e\right ) - 1056 i \, b f h e^{3} \log \left (f x + e\right ) - 144 \, a f x e^{3} + 300 \, b f x e^{3} + 72 \, b e^{4} \log \left (c f x + c e\right )^{2} + 144 \, a e^{4} \log \left (f x + e\right ) - 300 \, b e^{4} \log \left (f x + e\right )}{144 \, d f^{5}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^4*(a+b*log(c*(f*x+e)))/(d*f*x+d*e),x, algorithm="giac")

[Out]

1/144*(72*b*f^4*h^4*log(c*f*x + c*e)^2 + 576*I*b*f^4*h^3*x*log(c*f*x + c*e) - 432*b*f^4*h^2*x^2*log(c*f*x + c*
e) - 192*I*b*f^4*h*x^3*log(c*f*x + c*e) + 36*b*f^4*x^4*log(c*f*x + c*e) - 288*I*b*f^3*h^3*e*log(c*f*x + c*e)^2
 + 144*a*f^4*h^4*log(f*x + e) + 576*I*a*f^4*h^3*x - 576*I*b*f^4*h^3*x - 432*a*f^4*h^2*x^2 + 216*b*f^4*h^2*x^2
- 192*I*a*f^4*h*x^3 + 64*I*b*f^4*h*x^3 + 36*a*f^4*x^4 - 9*b*f^4*x^4 + 864*b*f^3*h^2*x*e*log(c*f*x + c*e) + 288
*I*b*f^3*h*x^2*e*log(c*f*x + c*e) - 48*b*f^3*x^3*e*log(c*f*x + c*e) - 576*I*a*f^3*h^3*e*log(f*x + e) + 576*I*b
*f^3*h^3*e*log(f*x + e) + 864*a*f^3*h^2*x*e - 1296*b*f^3*h^2*x*e + 288*I*a*f^3*h*x^2*e - 240*I*b*f^3*h*x^2*e -
 48*a*f^3*x^3*e + 28*b*f^3*x^3*e - 432*b*f^2*h^2*e^2*log(c*f*x + c*e)^2 - 576*I*b*f^2*h*x*e^2*log(c*f*x + c*e)
 + 72*b*f^2*x^2*e^2*log(c*f*x + c*e) - 864*a*f^2*h^2*e^2*log(f*x + e) + 1296*b*f^2*h^2*e^2*log(f*x + e) - 576*
I*a*f^2*h*x*e^2 + 1056*I*b*f^2*h*x*e^2 + 72*a*f^2*x^2*e^2 - 78*b*f^2*x^2*e^2 + 288*I*b*f*h*e^3*log(c*f*x + c*e
)^2 - 144*b*f*x*e^3*log(c*f*x + c*e) + 576*I*a*f*h*e^3*log(f*x + e) - 1056*I*b*f*h*e^3*log(f*x + e) - 144*a*f*
x*e^3 + 300*b*f*x*e^3 + 72*b*e^4*log(c*f*x + c*e)^2 + 144*a*e^4*log(f*x + e) - 300*b*e^4*log(f*x + e))/(d*f^5)

________________________________________________________________________________________

Mupad [B]
time = 0.55, size = 661, normalized size = 2.10 \begin {gather*} x^3\,\left (\frac {i^3\,\left (12\,a\,f\,h+b\,e\,i-4\,b\,f\,h\right )}{9\,d\,f^2}-\frac {e\,i^4\,\left (4\,a-b\right )}{12\,d\,f^2}\right )-x^2\,\left (\frac {e\,\left (\frac {i^3\,\left (12\,a\,f\,h+b\,e\,i-4\,b\,f\,h\right )}{3\,d\,f^2}-\frac {e\,i^4\,\left (4\,a-b\right )}{4\,d\,f^2}\right )}{2\,f}-\frac {i^2\,\left (12\,a\,f^2\,h^2-b\,e^2\,i^2-6\,b\,f^2\,h^2+4\,b\,e\,f\,h\,i\right )}{4\,d\,f^3}\right )+x\,\left (\frac {12\,b\,e^3\,i^4+48\,a\,f^3\,h^3\,i-48\,b\,f^3\,h^3\,i-48\,b\,e^2\,f\,h\,i^3+72\,b\,e\,f^2\,h^2\,i^2}{12\,d\,f^4}+\frac {e\,\left (\frac {e\,\left (\frac {i^3\,\left (12\,a\,f\,h+b\,e\,i-4\,b\,f\,h\right )}{3\,d\,f^2}-\frac {e\,i^4\,\left (4\,a-b\right )}{4\,d\,f^2}\right )}{f}-\frac {i^2\,\left (12\,a\,f^2\,h^2-b\,e^2\,i^2-6\,b\,f^2\,h^2+4\,b\,e\,f\,h\,i\right )}{2\,d\,f^3}\right )}{f}\right )+f\,\ln \left (c\,\left (e+f\,x\right )\right )\,\left (\frac {b\,i^4\,x^4}{4\,d\,f^2}+\frac {b\,i^2\,x^2\,\left (e^2\,i^2-4\,e\,f\,h\,i+6\,f^2\,h^2\right )}{2\,d\,f^4}-\frac {b\,i^3\,x^3\,\left (e\,i-4\,f\,h\right )}{3\,d\,f^3}-\frac {b\,i\,x\,\left (e^3\,i^3-4\,e^2\,f\,h\,i^2+6\,e\,f^2\,h^2\,i-4\,f^3\,h^3\right )}{d\,f^5}\right )+\frac {\ln \left (e+f\,x\right )\,\left (12\,a\,e^4\,i^4+12\,a\,f^4\,h^4-25\,b\,e^4\,i^4-48\,a\,e\,f^3\,h^3\,i-48\,a\,e^3\,f\,h\,i^3+48\,b\,e\,f^3\,h^3\,i+88\,b\,e^3\,f\,h\,i^3+72\,a\,e^2\,f^2\,h^2\,i^2-108\,b\,e^2\,f^2\,h^2\,i^2\right )}{12\,d\,f^5}+\frac {b\,{\ln \left (c\,\left (e+f\,x\right )\right )}^2\,\left (e^4\,i^4-4\,e^3\,f\,h\,i^3+6\,e^2\,f^2\,h^2\,i^2-4\,e\,f^3\,h^3\,i+f^4\,h^4\right )}{2\,d\,f^5}+\frac {i^4\,x^4\,\left (4\,a-b\right )}{16\,d\,f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((h + i*x)^4*(a + b*log(c*(e + f*x))))/(d*e + d*f*x),x)

[Out]

x^3*((i^3*(12*a*f*h + b*e*i - 4*b*f*h))/(9*d*f^2) - (e*i^4*(4*a - b))/(12*d*f^2)) - x^2*((e*((i^3*(12*a*f*h +
b*e*i - 4*b*f*h))/(3*d*f^2) - (e*i^4*(4*a - b))/(4*d*f^2)))/(2*f) - (i^2*(12*a*f^2*h^2 - b*e^2*i^2 - 6*b*f^2*h
^2 + 4*b*e*f*h*i))/(4*d*f^3)) + x*((12*b*e^3*i^4 + 48*a*f^3*h^3*i - 48*b*f^3*h^3*i - 48*b*e^2*f*h*i^3 + 72*b*e
*f^2*h^2*i^2)/(12*d*f^4) + (e*((e*((i^3*(12*a*f*h + b*e*i - 4*b*f*h))/(3*d*f^2) - (e*i^4*(4*a - b))/(4*d*f^2))
)/f - (i^2*(12*a*f^2*h^2 - b*e^2*i^2 - 6*b*f^2*h^2 + 4*b*e*f*h*i))/(2*d*f^3)))/f) + f*log(c*(e + f*x))*((b*i^4
*x^4)/(4*d*f^2) + (b*i^2*x^2*(e^2*i^2 + 6*f^2*h^2 - 4*e*f*h*i))/(2*d*f^4) - (b*i^3*x^3*(e*i - 4*f*h))/(3*d*f^3
) - (b*i*x*(e^3*i^3 - 4*f^3*h^3 + 6*e*f^2*h^2*i - 4*e^2*f*h*i^2))/(d*f^5)) + (log(e + f*x)*(12*a*e^4*i^4 + 12*
a*f^4*h^4 - 25*b*e^4*i^4 - 48*a*e*f^3*h^3*i - 48*a*e^3*f*h*i^3 + 48*b*e*f^3*h^3*i + 88*b*e^3*f*h*i^3 + 72*a*e^
2*f^2*h^2*i^2 - 108*b*e^2*f^2*h^2*i^2))/(12*d*f^5) + (b*log(c*(e + f*x))^2*(e^4*i^4 + f^4*h^4 + 6*e^2*f^2*h^2*
i^2 - 4*e*f^3*h^3*i - 4*e^3*f*h*i^3))/(2*d*f^5) + (i^4*x^4*(4*a - b))/(16*d*f)

________________________________________________________________________________________